home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
1000 Apple LAN Literacy
/
1000 Apple LAN Literacy.iso
/
Apple LAN Literacy for Floppies
/
Apple LAN Literacy disk 8 of 8
/
N&C Help
/
N&C Help
/
stack.txt
< prev
Wrap
Text File
|
1989-08-22
|
10KB
|
351 lines
-- stack: in
-- format: 8 (HyperCard 1)
-- flags: 0x1000 (none)
-- protect password hash: 0
-- maximum user level: 5 (scripting)
-- window: Rect(x1=0, y1=0, x2=0, y2=0)
-- screen: Rect(x1=0, y1=0, x2=0, y2=0)
-- card dimensions: w=0 h=0
-- scroll: x=0 y=0
-- background count: 4
-- first background id: 17060
-- card count: 19
-- first card id: 3967
-- list block id: 4207
-- print block id: 3351
-- font table block id: 0
-- style table block id: 0
-- free block count: 0
-- free size: 0 bytes
-- total size: 112128 bytes
-- stack block size: 20992 bytes
-- created by hypercard version: 0x01228000
-- compacted by hypercard version: 0x01228000
-- modified by hypercard version: 0x01228000
-- opened by hypercard version: 0x01228000
-- patterns[0]: 0x0000000000000000
-- patterns[1]: 0x8000000008000000
-- patterns[2]: 0x8800220088002200
-- patterns[3]: 0x8888222288882222
-- patterns[4]: 0x88AA22AA88AA22AA
-- patterns[5]: 0xCCAA33AACCAA33AA
-- patterns[6]: 0xEEAABBAAEEAABBAA
-- patterns[7]: 0xEEBBBBEEEEBBBBEE
-- patterns[8]: 0xFFBBFFEEFFBBFFEE
-- patterns[9]: 0xFFBBFFFFFFBBFFFF
-- patterns[10]: 0x8010022001084004
-- patterns[11]: 0xFFFFFFFFFFFFFFFF
-- patterns[12]: 0x8822882288228822
-- patterns[13]: 0x1122448811224488
-- patterns[14]: 0xC4800C6843023026
-- patterns[15]: 0xB130031BD8C00C8D
-- patterns[16]: 0x00FF00FF00FF00FF
-- patterns[17]: 0x8822552288225522
-- patterns[18]: 0x8855225588552255
-- patterns[19]: 0x77DD77DD77DD77DD
-- patterns[20]: 0x8000000000000000
-- patterns[21]: 0xAA55AA55AA55AA55
-- patterns[22]: 0x038448300C020101
-- patterns[23]: 0x8244394482010101
-- patterns[24]: 0x8814224188412214
-- patterns[25]: 0x8080413E080814E3
-- patterns[26]: 0x22048C7422179810
-- patterns[27]: 0xBE808808EB088880
-- patterns[28]: 0x25C8328964244C92
-- patterns[29]: 0xA29C41BE2AC914EB
-- patterns[30]: 0x40A00000040A0000
-- patterns[31]: 0x8040200002040800
-- patterns[32]: 0xAA00800088008000
-- patterns[33]: 0xFF80808080808080
-- patterns[34]: 0x081C22C180010204
-- patterns[35]: 0xFF808080FF080808
-- patterns[36]: 0xF87422478F172271
-- patterns[37]: 0xBF00BFBFB0B0B0B0
-- patterns[38]: 0xFF7FBE5DA2418000
-- patterns[39]: 0xFAF5FAF5A050A050
-- checksum: 0x0
----- HyperTalk script -----
---------------------------------------------------------------------
-- “Network & Communications”
-- “Apple LAN Literacy Course”
-- © 1989 Apple Computer, Inc. &
-- © 1989 Courseware, Inc. &
-- © 1989 HyperPro, Inc.
--
-- Version 1.0f5
----------------------------------------------------------------------
-- Stack: N&C Help
--
HANDLERS: openstack,findSetUp,Lesson,Help,saveMyPlace,goItem,beenHereFlag,
-- SpecialStudentServices,SpecialInstantReference,
-- returnToCourse,SSQuit,doMenu,BookMark,saveMyPlace,
-- saveIdentifier,popWhere
-- FUNCTIONS: whereAmI,validField
-- RESOURCES:
-- ICON: Student Services,GrayPrev,Help,Prev Card,Lg #2,Lg #3,
-- Lg #1 Outline,Lg #2 Outline,Lg #3 Outline,Lg #1,#1,#2,
-- #1 Outline,#2 Outline,GrayNext,Next Card,Grey Up Arrow,
-- Up Arrow,To Menus,Lg #4,Lg #4 Outline,#3,#4,#5,
-- #3 Outline,#4 Outline,#5 Outline
-- XFCN: kPopUp
-- vers:
-- DITL: Answer
-- FONT: Garamond
--
----------------------------------------------------------------------
--
-- By Apple Computer, Inc., Courseware, Inc. & HyperPro, Inc.
--
----------------------------------------------------------------------
on openstack
global setupOk
global helpButtonStatus,toNavCard
put empty into helpButtonStatus
put empty into toNavCard
hide menuBar
hide msg
get the version
if it < 1.2 then
answer "This stack requires HyperCard v1.2.2 or later."
go back
exit to HyperCard
end if
if setupOk is empty then findSetup -- otherwise it's true, continue
end openStack
on findSetUp
set lockmessages to true
set cursor to watch
go stack "Literacy Course"
if the result is "cancel" then
answer "Unable to launch course."
domenu Quit Hypercard
exit to Hypercard -- exit calling handlers
else -- found course setup card
set lockmessages to false
send openstack to this stack -- the setup stack
exit to HyperCard
end if
end findSetUP
on Lesson
answer "This button returns you to the Menus." with "Go There" or "Stay Here"
if it is "Stay Here" then exit to hyperCard
set lockmessages to true
lock screen
go "Literacy Main Menu"
opencard
unlock screen with visual scroll down
end Lesson
on Help
lock screen
answer "This will return you to this Help section."
end Help
on saveMyPlace
global whereWeCameFrom
if (last item of whereWeCameFrom) is not (the long id of this cd) then
put the long id of this cd into item (number of items in whereWeCameFrom) + 1 of whereWeCameFrom
end if
end saveMyPlace
on goItem
put last char of the short name of the target into temp
put "#" & temp into btnNumb -- btn names are #1, #2, etc
put "422" & temp into iconNumb -- or "424" for large numbers
set the icon of btn btnNumb to iconNumb
go cd temp + the number of this cd
end goItem
on beenHereFlag itemNum,lineNum
global helpButtonStatus
if line lineNum of helpButtonStatus is empty
then put "dummy" into line lineNum of helpButtonStatus
put "true" into item itemNum of line lineNum of helpButtonStatus
if item 1 of line lineNum of helpButtonStatus = "dummy"
then put empty into item 1 of line lineNum of helpButtonStatus
end beenHereFlag
on SpecialStudentServices
set hilite of the target to true
get kPopUp("init",999) -- creates menu in memory
put "Main Menu;BookMark…;Note…;SnapShot…;Index;Scrapbook;" & "Search…;Map;Glossary;Quit" into choice
get kPopUp("append",999,choice) -- 999 is reference #
get kPopUp("pop",999,1,bottom of the target,left of the target + 1)
-- pop returns ID number of menu, number of item selected
set cursor to watch
put kPopUp("GetItem",item 1 of it,item 2 of it) into command
-- returns text of item
get kPopUp("toss",999) -- remove menu from memory
set hilite of the target to false
if last char of command is "…" then delete last char of command
if command is "Quit" then
answer "This feature exits the course and lets you save your place."
exit to hypercard
end if
if command ≠ "no such menu" then
go cd command
end if
end SpecialStudentServices
on SpecialInstantReference
lock screen
get the clickloc
put item 1 of it into x
put item 2 of it into y
put left of the target + width of the target - x into x1
put y - top of the target into y1
put x - item 1 of the loc of the target into x2
put y - item 2 of the loc of the target into y2
subtract left of the target from x
subtract top of the target from y
if SQRT(x2*x2 + y2*y2) > 27 then exit SpecialInstantReference
if x1 < y1
then
if x < y
then go cd "Practice"
else go cd "Example"
else
if x < y
then go cd "Information"
else go cd "Content"
end if
end SpecialInstantReference
on returnToCourse
global whereWeCameFrom
answer "This button returns you to the Course." with "Go there" or "Stay Here"
if it is "Stay here" then exit to hyperCard
lock screen
set cursor to watch
put the id of this cd && "of stack" && quote & the short name of this stack & quote into thisPlace
if (last item of whereWeCameFrom = thisPlace) then
delete last item of whereWeCameFrom
end if
set lockMessages to true
go last item of whereWeCameFrom
send openCard to this card
set lockMessages to false
delete last item of whereWeCameFrom
unlock screen with visual dissolve
end returnToCourse
on SSQuit
global gSystemFile,useSS,mapTracker,menuHilites,course
global bookmarkPref,wherewecamefrom,OKtoQuit
put false into fromScrapbook --*!* was whereamI()
if not useSS then put true into fromScrapbook -- no bookmarks
if fromScrapbook then
answer "Do you want to quit the course?" with "Cancel" or "Yes, quit"
if it is "Cancel" then
exit to Hypercard
end if
else
if bookmarkPref then
answer "Create Bookmark & quit this course?" with "Cancel" or "Just quit" or "OK"
else
answer "Create Bookmark & quit this course?" with "Cancel" or "OK" or "Just quit"
end if
if it is "Cancel" then exit to hypercard
if it is "OK" then bookmark
end if
if useSS and course then
open file gSystemFile
read from file gSystemFile for 16384
put line 1 to 2 of it into theContents
close file gSystemFile
put wherewecamefrom into line 3 of theContents
put mapTracker into line 4 of theContents
-- put return & menuHilites after line 5 of theContents --*!* ANP only
open file gSystemfile
write theContents to file gSystemFile
close file gSystemFile
lock screen
global scrapFile
go stack scrapFile
put theContents into cd fld "hidden name"
end if
put true into OKtoQuit
domenu "Quit Hypercard"
exit to hypercard
end SSquit
on doMenu var
global OKtoQuit
if OKtoQuit is empty then put false into OKtoQuit
if var = "Quit HyperCard" and OKtoQuit is false then ssQuit
else if var = "Quit HyperCard" and OKtoQuit then pass doMenu
else pass doMenu
end doMenu
on BookMark
global scrapFile
saveIdentifier
saveMyPlace
put false into madeBookMark
push cd
set cursor to watch
lock screen
set lockMessages to true
go cd "index" of stack scrapFile
if the result is "cancel" then popWhere -- exits
put makeBookMark() into myResult
if myResult is "successful" then put true into madeBookMark
pop cd
set lockmessages to false
if madeBookMark then unlock screen with iris open to black
else unlock screen
end bookMark
on saveMyPlace
global whereWeCameFrom
put the id of this cd && "of stack" && quote & the short name of this stack & quote into thisPlace
if not (last item of whereWeCameFrom = thisPlace) then
put thisPlace into item (number of items in whereWeCameFrom) + 1 of whereWeCameFrom
end if
end saveMyPlace
on saveIdentifier
global identifier
put the short name of this cd into identifier
end saveIdentifier
on popWhere
global whereWeCameFrom
pop card
delete last item of whereWeCameFrom
set lockMessages to false
exit to Hypercard
end popWhere